package com.wx.entity;

import com.alibaba.excel.annotation.ExcelIgnore;
import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.write.style.ColumnWidth;
import com.wx.common.BaseEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.persistence.Column;
import javax.persistence.Table;
import javax.persistence.Transient;
import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import java.io.Serializable;
import java.math.BigDecimal;

@Table(name = "sys_hospital")
@Data
@ApiModel(value = "sysHospital")
public class SysHospital extends BaseEntity implements Serializable {

    private static final long serialVersionUID = -1186510500035530179L;
    /**
     * 医院编码
     */
    @Column(name = "hospital_code")
    @ApiModelProperty(value = "医院编码")
    @ExcelIgnore
    private String hospitalCode;
    /**
     * 医院名称
     */
    @Column(name = "hospital_name")
    @ApiModelProperty(value = "医院名称")
    @NotEmpty(message = "医院名称不能为空")
    @ExcelProperty(value = "机构名称", index = 0)
    @ColumnWidth(value = 25)
    private String hospitalName;
    /**
     * 类型
     */
    @Column(name = "hospital_type")
    @ApiModelProperty(value = "类型")
    @ExcelProperty(value = "机构类型", index = 1)
    @ColumnWidth(value = 25)
    private String hospitalType;
    /**
     * 省份编码
     */
    @Column(name = "province_code")
    @ApiModelProperty(value = "省份编码")
    @NotEmpty(message = "省份编码不能为空")
    @ExcelIgnore
    private String provinceCode;
    /**
     * 城市编码
     */
    @Column(name = "city_code")
    @ApiModelProperty(value = "城市编码")
    @NotEmpty(message = "城市编码不能为空")
    @ExcelIgnore
    private String cityCode;
    /**
     * 区县编码
     */
    @Column(name = "area_code")
    @ApiModelProperty(value = "区县编码")
    @NotEmpty(message = "区县编码不能为空")
    @ExcelIgnore
    private String areaCode;
    /**
     * 详细地址
     */
    @Column(name = "detail_address")
    @ApiModelProperty(value = "详细地址")
    @ExcelIgnore
    private String detailAddress;
    /**
     * 经度
     */
    @Column(name = "longitude")
    @ApiModelProperty(value = "经度")
    @NotNull(message = "经度不能为空")
    @ExcelProperty(value = "经度", index = 5)
    private BigDecimal longitude;
    /**
     * 纬度
     */
    @Column(name = "latitude")
    @ApiModelProperty(value = "纬度")
    @NotNull(message = "纬度不能为空")
    @ExcelProperty(value = "纬度", index = 6)
    private BigDecimal latitude;


    /**
     * 区域
     */
    @Column(name = "region")
    @ApiModelProperty(value = "区域")
    @ExcelProperty(value = "区域", index = 8)
    private String region;

    /**
     * 大区
     */
    @Column(name = "big_region")
    @ApiModelProperty(value = "大区")
    @ExcelProperty(value = "大区", index = 9)
    private String bigRegion;


    /**
     * 省份名称
     */
    @ApiModelProperty(value = "省份名称")
    @Transient
    @ExcelProperty(value = "省", index = 2)
    private String provinceName;
    /**
     * 城市名称
     */
    @ApiModelProperty(value = "城市名称")
    @Transient
    @ExcelProperty(value = "市", index = 3)
    private String cityName;
    /**
     * 县名称
     */
    @ApiModelProperty(value = "县")
    @Transient
    @ExcelProperty(value = "县", index = 4)
    private String areaName;

    /**
     * 所属护士
     */
    @ApiModelProperty(value = "所属护士名称")
    @Transient
    @ExcelProperty(value = "所属护士", index = 7)
    @ColumnWidth(value = 25)
    private String nurseName;

    /**
     * 所属护士
     */
    @ApiModelProperty(value = "所属护士id")
    @Transient
    @ExcelIgnore
    private String nurseId;


    /**
     * 范围id
     */
    @ApiModelProperty(value = "范围id")
    @Transient
    @ExcelIgnore
    private String rangeId;

    @Transient
    @ExcelIgnore
    private String rangeName;



}